{extend name="layout" /}
{block name="content"}

<!-- {if condition="$uinfo.roleid == 9 && $info.kind == 'gouche' && $info.status == 1"}
<div class="tm-footer">
	<div class="tm-flex">
		<div class="tm-flex-1 all-height">
			<button class="mui-btn mui-btn-green cocoAjax" confirm="您确定收到奖励金了吗？" ajax-url="/v2/client/confirm_jianglj" ajax-callback="suc_jlj" ajax-data="{ ocid:{$info.id}}" type="button">确认收到奖励金</button>
		</div>
	</div>
</div>
{elseif condition="in_array($uinfo.roleid, [8,10,11])"}
<div class="tm-footer">
	<div class="tm-flex">
		{if condition="$info.status == 0 || $info.status == 5"}
		<div class="tm-flex-1 all-height">
			<a href="{:url('order_edit', ['id'=>$info.id,'token'=>$token,'timestamp'=>time()])}" class="mui-btn mui-btn-green href">编辑</a>
		</div>
		{/if}
		<div class="tm-flex-1 all-height">
			<button class="mui-btn mui-btn-danger cocoAjax" confirm="确定要删除该订单吗？" ajax-url="{:url('v1/order_client/del_order')}" ajax-data="{ id:{$info.id}}" ajax-callback="suc_del" type="button">删除</button>
		</div>
	</div>
</div>
{/if} -->

<div class="mui-content">
	<div class="uk-margin-small-top controll-atav-1">
		<div class="tm-df-size">
			<ul class="mui-table-view max">
				<li class="mui-table-view-cell">
					<div class="tm-cell-pad">
						<div class="tm-flex">
							<div class="tm-6em tm-flex-head">
								<span class="tm-font-gray">付款状态</span>
							</div>
							<div class="tm-flex-1">
								{if condition="$info.status == 2"}
								<div class="tm-font-boldx mui-ellipsis">已付款</div>
								{/if}
							</div>
						</div>
					</div>
				</li>
				<li class="mui-table-view-cell">
					<div class="tm-cell-pad">
						<div class="tm-flex">
							<div class="tm-6em tm-flex-head">
								<span class="tm-font-gray">单号</span>
							</div>
							<div class="tm-flex-1">
								<div class="tm-font-boldx mui-ellipsis">{$info.id}</div>
							</div>
						</div>
					</div>
				</li>
				<li class="mui-table-view-cell">
					<div class="tm-cell-pad">
						<div class="tm-flex">
							<div class="tm-6em tm-flex-head">
								<span class="tm-font-gray">成交客户</span>
							</div>
							<div class="tm-flex-1">
								<div class="tm-font-boldx mui-ellipsis">{$info.name}</div>
							</div>
						</div>
					</div>
				</li>
				<li class="mui-table-view-cell">
					<div class="tm-cell-pad">
						<div class="tm-flex">
							<div class="tm-6em tm-flex-head">
								<span class="tm-font-gray">线索分类</span>
							</div>
							<div class="tm-flex-1">
								<div class="tm-font-boldx mui-ellipsis">{:config('CLIENT_KIND.'.$info.kind)}</div>
							</div>
						</div>
					</div>
				</li>
				{eq name="info.kind" value="gouche"}
				<li class="mui-table-view-cell">
					<div class="tm-cell-pad">
						<div class="tm-flex">
							<div class="tm-6em tm-flex-head">
								<span class="tm-font-gray">购买车型</span>
							</div>
							<div class="tm-flex-1">
								<div class="tm-font-boldx mui-ellipsis">{$info.product}</div>
							</div>
						</div>
					</div>
				</li>
				{/eq}
				<li class="mui-table-view-cell">
					<div class="tm-cell-pad">
						<div class="tm-flex">
							<div class="tm-6em tm-flex-head">
								<span class="tm-font-gray">成交总额</span>
							</div>
							<div class="tm-flex-1">
								<div class="tm-font-boldx mui-ellipsis">¥{$info.price}</div>
							</div>
						</div>
					</div>
				</li>
				<li class="mui-table-view-cell">
					<div class="tm-cell-pad">
						<div class="tm-flex">
							<div class="tm-6em tm-flex-head">
								<span class="tm-font-gray">购车时间</span>
							</div>
							<div class="tm-flex-1">
								<div class="tm-font-boldx mui-ellipsis">{$info.sucdate}</div>
							</div>
						</div>
					</div>
				</li>
				<li class="mui-table-view-cell">
					<a class="" href="javascript:;"  id="layerT">
						<div class="tm-cell-pad">
							<div class="tm-flex">
								<div class="tm-6em tm-flex-head">
									<span class="tm-font-gray">图片展示</span>
								</div>
								<div class="tm-flex-1">
									<div class="tm-flex">
										<div class="tm-atav tm-flex-head">
											<div class="tm-location-parent">
												<div class="tm-location-img" style="background-image: url({$info.carthumb});"></div>
												<img class="redundant-img" src="{$images_path}px-1.png" alt="" width="100"  data-preview-src="{$info.carthumb}" data-preview-group="1">
											</div>
										</div>
									</div>
								</div>
							</div>
						</div>
					</a>
				</li>
				<li class="mui-table-view-cell">
					<div class="tm-cell-pad">
						<div class="tm-flex">
							<div class="tm-6em tm-flex-head">
								<span class="tm-font-gray">备注</span>
							</div>
							<div class="tm-flex-1">
								<div class="tm-font-boldx mui-ellipsis">{$info.remark}</div>
							</div>
						</div>
					</div>
				</li>
			</ul>
		</div>

		<div class="tm-df-size uk-margin-small-top">
			<ul class="mui-table-view max">
				<li class="mui-table-view-cell">
					<div class="tm-cell-pad">
						<div class="tm-flex">
							<div class="tm-6em tm-flex-head">
								<span class="tm-font-gray">所属经纪人</span>
							</div>
							<div class="tm-flex-1">
								<div class="tm-font-boldx mui-ellipsis">{$info.uinfo.realname}</div>
							</div>
						</div>
					</div>
				</li>
			</ul>
		</div>
	</div>
</div>

<div class="main-layer-group" id="main-layer-group">
	<div class="mask" id="main-mask">
	</div>
	<div class="content-list" style="top: 0px;">
		<div class="show-operation-btns tm-bg-white">
			<div class="uk-text-center tm-df-size">
				{if condition="$info.status == 0 || $info.status == 5"}
				<a href="{:url('order_edit', ['id'=>$info.id])}" class="operation-btn-item tm-block href">
					修改
				</a>
				{/if}
				<a href="javascript:" class="operation-btn-item tm-block cocoAjax" confirm="确定要删除该订单吗？" ajax-url="{:url('v1/order_client/del_order')}" ajax-data="{ id:{$info.id}}" ajax-callback="suc_del">
					删除
				</a>
			</div>
		</div>
	</div>
</div>





{/block}


{block name="script"}

<script src="https://sijia.test.cmsthink.com/public/static/js/mui.zoom.js"></script>
<script src="https://sijia.test.cmsthink.com/public/static/js/mui.previewimage.js"></script>

<script type="text/javascript" charset="utf-8">
	//图片预览控制
	mui.previewImage();
</script>


<script type="text/javascript">
	function suc_del(obj, data) {
		coco_msg('删除成功');
		setTimeout(function() {
			coco_close_window();
		}, 300);
	}
	function suc_jlj(obj, data) {
		coco_msg('您已确认收到奖励金');
	}
</script>
<script type="text/javascript">
	var closeAll = function(){
		$("#main-layer-group").removeClass("active");
	}
	mui.ready(function(){
		mui(document).on("tap","#main-mask",function(){
			closeAll();
		})
	})
</script>


{/block}

